diff --git a/common/Makefile b/common/Makefile
index 08af1a8..1abf4ea 100644
--- a/common/Makefile
+++ b/common/Makefile
@@ -179,6 +179,7 @@
 COBJS-y += usb.o usb_hub.o
 COBJS-$(CONFIG_USB_STORAGE) += usb_storage.o
 endif
+COBJS-$(CONFIG_CMD_USB_MASS_STORAGE) += cmd_usb_mass_storage.o
 COBJS-$(CONFIG_CMD_XIMG) += cmd_ximg.o
 COBJS-$(CONFIG_YAFFS2) += cmd_yaffs2.o
 COBJS-$(CONFIG_CMD_SPL) += cmd_spl.o
diff --git a/common/cmd_usb_mass_storage.c b/common/cmd_usb_mass_storage.c
new file mode 100644
index 0000000..87a5f2f
--- /dev/null
+++ b/common/cmd_usb_mass_storage.c
@@ -0,0 +1,86 @@
+/*
+ * Copyright (C) 2011 Samsung Electronics
+ * Lukasz Majewski <l.majewski@samsung.com>
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License as
+ * published by the Free Software Foundation; either version 2 of
+ * the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ */
+
+#include <errno.h>
+#include <common.h>
+#include <command.h>
+#include <g_dnl.h>
+#include <usb_mass_storage.h>
+
+int do_usb_mass_storage(cmd_tbl_t *cmdtp, int flag,
+			       int argc, char * const argv[])
+{
+	char *ep;
+	unsigned int dev_num = 0, offset = 0, part_size = 0;
+	int rc;
+
+	struct ums_board_info *ums_info;
+	static char *s = "ums";
+
+	if (argc < 2) {
+		printf("usage: ums <dev> - e.g. ums 0\n");
+		return 0;
+	}
+
+	dev_num = (int)simple_strtoul(argv[1], &ep, 16);
+
+	if (dev_num) {
+		puts("\nSet eMMC device to 0! - e.g. ums 0\n");
+		goto fail;
+	}
+
+	board_usb_init();
+	ums_info = board_ums_init(dev_num, offset, part_size);
+
+	if (!ums_info) {
+		printf("MMC: %d -> NOT available\n", dev_num);
+		goto fail;
+	}
+	rc = fsg_init(ums_info);
+	if (rc) {
+		printf("cmd ums: fsg_init failed\n");
+		goto fail;
+	}
+
+	g_dnl_register(s);
+
+	while (1) {
+		/* Handle control-c and timeouts */
+		if (ctrlc()) {
+			printf("The remote end did not respond in time.\n");
+			goto exit;
+		}
+		usb_gadget_handle_interrupts();
+		/* Check if USB cable has been detached */
+		if (fsg_main_thread(NULL) == EIO)
+			goto exit;
+	}
+exit:
+	g_dnl_unregister();
+	return 0;
+
+fail:
+	return -1;
+}
+
+U_BOOT_CMD(ums, CONFIG_SYS_MAXARGS, 1, do_usb_mass_storage,
+	"Use the UMS [User Mass Storage]",
+	"ums - User Mass Storage Gadget"
+);
diff --git a/drivers/usb/gadget/g_dnl.c b/drivers/usb/gadget/g_dnl.c
index a5a4c1f..cc3f344 100644
--- a/drivers/usb/gadget/g_dnl.c
+++ b/drivers/usb/gadget/g_dnl.c
@@ -31,6 +31,7 @@
 
 #include "gadget_chips.h"
 #include "composite.c"
+#include "f_mass_storage.c"
 
 /*
  * One needs to define the following:
@@ -104,6 +105,8 @@
 	printf("GADGET DRIVER: %s\n", s);
 	if (!strcmp(s, "usb_dnl_dfu"))
 		ret = dfu_add(c);
+	else if (!strcmp(s, "usb_dnl_ums"))
+		ret = fsg_add(c);
 
 	return ret;
 }
@@ -188,6 +191,9 @@
 	if (!strcmp(type, "dfu")) {
 		strcpy(name, shortname);
 		strcat(name, type);
+	} else if (!strcmp(type, "ums")) {
+		strcpy(name, shortname);
+		strcat(name, type);
 	} else {
 		printf("%s: unknown command: %s\n", __func__, type);
 		return -EINVAL;
diff --git a/include/usb_mass_storage.h b/include/usb_mass_storage.h
new file mode 100644
index 0000000..ffc3a13
--- /dev/null
+++ b/include/usb_mass_storage.h
@@ -0,0 +1,55 @@
+/*
+ * Copyright (C) 2011 Samsung Electrnoics
+ * Lukasz Majewski <l.majewski@samsung.com>
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License as
+ * published by the Free Software Foundation; either version 2 of
+ * the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * aloong with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ */
+
+#ifndef __USB_MASS_STORAGE_H__
+#define __USB_MASS_STORAGE_H__
+
+#define SECTOR_SIZE		0x200
+
+#include <mmc.h>
+
+struct ums_device {
+	struct mmc *mmc;
+	int dev_num;
+	int offset;
+	int part_size;
+};
+
+struct ums_board_info {
+	int (*read_sector)(struct ums_device *ums_dev,
+			   ulong start, lbaint_t blkcnt, void *buf);
+	int (*write_sector)(struct ums_device *ums_dev,
+			    ulong start, lbaint_t blkcnt, const void *buf);
+	void (*get_capacity)(struct ums_device *ums_dev,
+			     long long int *capacity);
+	const char *name;
+	struct ums_device ums_dev;
+};
+
+extern void board_usb_init(void);
+
+extern int fsg_init(struct ums_board_info *);
+extern void fsg_cleanup(void);
+extern struct ums_board_info *board_ums_init(unsigned int,
+					     unsigned int, unsigned int);
+extern int usb_gadget_handle_interrupts(void);
+extern int fsg_main_thread(void *);
+
+#endif /* __USB_MASS_STORAGE_H__ */
